#include<stdio.h>


int Circlemovebit(unsigned num,int movenum)
{
	if(movenum==0) return num;
	else if(movenum>0)
	{
		return (num<<movenum);
	}
	else
	{
		return (num>>(-movenum));
	}
}

int main()
{
	unsigned num;
	int movenum;
	printf("请输入一个八进制数:\n");
	scanf("%o",&num);
	printf("请输入要移的位数:\n");
	scanf("%d",&movenum);
	int result=Circlemovebit(num,movenum);
	printf("移位的结果是:%#o\n",result);
	return 0;
}
